\(\int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx\) [47]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [F]
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 24, antiderivative size = 46 \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=-\frac {2 \cot (c+d x)}{a d}-\frac {\cot ^3(c+d x)}{3 a d}+\frac {\tan (c+d x)}{a d} \]

[Out]

-2*cot(d*x+c)/a/d-1/3*cot(d*x+c)^3/a/d+tan(d*x+c)/a/d

Rubi [A] (verified)

Time = 0.06 (sec) , antiderivative size = 46, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {3254, 2700, 276} \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=\frac {\tan (c+d x)}{a d}-\frac {\cot ^3(c+d x)}{3 a d}-\frac {2 \cot (c+d x)}{a d} \]

[In]

Int[Csc[c + d*x]^4/(a - a*Sin[c + d*x]^2),x]

[Out]

(-2*Cot[c + d*x])/(a*d) - Cot[c + d*x]^3/(3*a*d) + Tan[c + d*x]/(a*d)

Rule 276

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*(a + b*x^n)^p,
 x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0]

Rule 2700

Int[csc[(e_.) + (f_.)*(x_)]^(m_.)*sec[(e_.) + (f_.)*(x_)]^(n_.), x_Symbol] :> Dist[1/f, Subst[Int[(1 + x^2)^((
m + n)/2 - 1)/x^m, x], x, Tan[e + f*x]], x] /; FreeQ[{e, f}, x] && IntegersQ[m, n, (m + n)/2]

Rule 3254

Int[(u_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]^2)^(p_), x_Symbol] :> Dist[a^p, Int[ActivateTrig[u*cos[e + f*x
]^(2*p)], x], x] /; FreeQ[{a, b, e, f, p}, x] && EqQ[a + b, 0] && IntegerQ[p]

Rubi steps \begin{align*} \text {integral}& = \frac {\int \csc ^4(c+d x) \sec ^2(c+d x) \, dx}{a} \\ & = \frac {\text {Subst}\left (\int \frac {\left (1+x^2\right )^2}{x^4} \, dx,x,\tan (c+d x)\right )}{a d} \\ & = \frac {\text {Subst}\left (\int \left (1+\frac {1}{x^4}+\frac {2}{x^2}\right ) \, dx,x,\tan (c+d x)\right )}{a d} \\ & = -\frac {2 \cot (c+d x)}{a d}-\frac {\cot ^3(c+d x)}{3 a d}+\frac {\tan (c+d x)}{a d} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.11 (sec) , antiderivative size = 49, normalized size of antiderivative = 1.07 \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=\frac {-\frac {5 \cot (c+d x)}{3 d}-\frac {\cot (c+d x) \csc ^2(c+d x)}{3 d}+\frac {\tan (c+d x)}{d}}{a} \]

[In]

Integrate[Csc[c + d*x]^4/(a - a*Sin[c + d*x]^2),x]

[Out]

((-5*Cot[c + d*x])/(3*d) - (Cot[c + d*x]*Csc[c + d*x]^2)/(3*d) + Tan[c + d*x]/d)/a

Maple [A] (verified)

Time = 0.60 (sec) , antiderivative size = 35, normalized size of antiderivative = 0.76

method result size
derivativedivides \(\frac {\tan \left (d x +c \right )-\frac {1}{3 \tan \left (d x +c \right )^{3}}-\frac {2}{\tan \left (d x +c \right )}}{d a}\) \(35\)
default \(\frac {\tan \left (d x +c \right )-\frac {1}{3 \tan \left (d x +c \right )^{3}}-\frac {2}{\tan \left (d x +c \right )}}{d a}\) \(35\)
risch \(\frac {16 i \left (2 \,{\mathrm e}^{2 i \left (d x +c \right )}-1\right )}{3 d a \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )^{3} \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}\) \(49\)
parallelrisch \(\frac {\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )+20 \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\cot ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )-90 \tan \left (\frac {d x}{2}+\frac {c}{2}\right )+20 \cot \left (\frac {d x}{2}+\frac {c}{2}\right )}{24 d a \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}\) \(82\)
norman \(\frac {\frac {1}{24 a d}+\frac {5 \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{6 d a}-\frac {15 \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{4 d a}+\frac {5 \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{6 d a}+\frac {\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )}{24 d a}}{\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3} \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}\) \(113\)

[In]

int(csc(d*x+c)^4/(a-a*sin(d*x+c)^2),x,method=_RETURNVERBOSE)

[Out]

1/d/a*(tan(d*x+c)-1/3/tan(d*x+c)^3-2/tan(d*x+c))

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 56, normalized size of antiderivative = 1.22 \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=-\frac {8 \, \cos \left (d x + c\right )^{4} - 12 \, \cos \left (d x + c\right )^{2} + 3}{3 \, {\left (a d \cos \left (d x + c\right )^{3} - a d \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )} \]

[In]

integrate(csc(d*x+c)^4/(a-a*sin(d*x+c)^2),x, algorithm="fricas")

[Out]

-1/3*(8*cos(d*x + c)^4 - 12*cos(d*x + c)^2 + 3)/((a*d*cos(d*x + c)^3 - a*d*cos(d*x + c))*sin(d*x + c))

Sympy [F]

\[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=- \frac {\int \frac {\csc ^{4}{\left (c + d x \right )}}{\sin ^{2}{\left (c + d x \right )} - 1}\, dx}{a} \]

[In]

integrate(csc(d*x+c)**4/(a-a*sin(d*x+c)**2),x)

[Out]

-Integral(csc(c + d*x)**4/(sin(c + d*x)**2 - 1), x)/a

Maxima [A] (verification not implemented)

none

Time = 0.34 (sec) , antiderivative size = 42, normalized size of antiderivative = 0.91 \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=\frac {\frac {3 \, \tan \left (d x + c\right )}{a} - \frac {6 \, \tan \left (d x + c\right )^{2} + 1}{a \tan \left (d x + c\right )^{3}}}{3 \, d} \]

[In]

integrate(csc(d*x+c)^4/(a-a*sin(d*x+c)^2),x, algorithm="maxima")

[Out]

1/3*(3*tan(d*x + c)/a - (6*tan(d*x + c)^2 + 1)/(a*tan(d*x + c)^3))/d

Giac [A] (verification not implemented)

none

Time = 0.33 (sec) , antiderivative size = 42, normalized size of antiderivative = 0.91 \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=\frac {\frac {3 \, \tan \left (d x + c\right )}{a} - \frac {6 \, \tan \left (d x + c\right )^{2} + 1}{a \tan \left (d x + c\right )^{3}}}{3 \, d} \]

[In]

integrate(csc(d*x+c)^4/(a-a*sin(d*x+c)^2),x, algorithm="giac")

[Out]

1/3*(3*tan(d*x + c)/a - (6*tan(d*x + c)^2 + 1)/(a*tan(d*x + c)^3))/d

Mupad [B] (verification not implemented)

Time = 13.85 (sec) , antiderivative size = 38, normalized size of antiderivative = 0.83 \[ \int \frac {\csc ^4(c+d x)}{a-a \sin ^2(c+d x)} \, dx=-\frac {-{\mathrm {tan}\left (c+d\,x\right )}^4+2\,{\mathrm {tan}\left (c+d\,x\right )}^2+\frac {1}{3}}{a\,d\,{\mathrm {tan}\left (c+d\,x\right )}^3} \]

[In]

int(1/(sin(c + d*x)^4*(a - a*sin(c + d*x)^2)),x)

[Out]

-(2*tan(c + d*x)^2 - tan(c + d*x)^4 + 1/3)/(a*d*tan(c + d*x)^3)